//
//  GFSearchTableViewCell.m
//  Qyer
//
//  Created by dlios on 15/10/24.
//  Copyright (c) 2015年 GF. All rights reserved.
//

#import "GFSearchTableViewCell.h"

@implementation GFSearchTableViewCell
- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier{
    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
    if (self) {
        _lable = [[UILabel alloc] initWithFrame:CGRectMake(110 * WIDTH, 5 * HEIGHT, SCREEN_WIDTH - 120 * WIDTH, 80 * HEIGHT)];
        [_lable setTextColor:[NightMode shareNightModeHandle].wordColor];
        [_lable setNumberOfLines:0];
        [_lable setFont:[UIFont systemFontOfSize: WIDTH * 12.]];
        [self.contentView addSubview:_lable];
        
        _image = [[UIImageView alloc] initWithFrame:CGRectMake(5 * WIDTH, 5 * WIDTH, 100 * WIDTH, 80 * HEIGHT)];
        [self.contentView addSubview:_image];
    }
    return self;
}

- (void)getSearchModel:(GFSearchModel *)model{
    [_image sd_setImageWithURL:[NSURL URLWithString:model.photo] placeholderImage:[UIImage imageNamed:@"zw.png"]];
    [_lable setText:model.title];
}

- (void)awakeFromNib {
    // Initialization code
}

- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];

    // Configure the view for the selected state
}

@end
